// Describe:
package main

import (
	"github.com/rs/zerolog/log"
	"github.com/spf13/viper"
	"wormhole/cmd"
	_ "wormhole/init"
	"wormhole/utils"
)

func main() {
	if viper.GetString("core.ip") == "" || viper.GetString("core.mode") == "auto" {
		ip := utils.NcInfo.Intranet
		viper.Set("core.ip", ip)
		log.Debug().Str("动态获取IP", ip).Send()
	}
	cmd.Execute()
}
